// 本項目接口地址
let currentTarget = ''
// 账务系统后台接口地址
let remote = ''

const LOCAL_DEV = 'https://yw2.cocloud.com' //  https://yw2.cocloud.com

if(process.env.NODE_ENV === 'development'){
  currentTarget = LOCAL_DEV
  remote = 'https://test2.cocloud.com'
}

if(location.hostname === 'yw2.cocloud.com'){
  remote = 'https://test2.cocloud.com'
}
if(location.hostname === 'm.cocloud.com'){
  remote = 'https://bp.cocloud.tw'
}

export const BASE_URL = currentTarget + '/api' // 可动态设置
export const BASE_URL_REMOTE = remote + '/api'

export const TOKEN_KEY  = 'salesman_token'
export const USER_KEY  = 'salesman_user'